from common.base import Base,get_driver
from selenium.webdriver.common.by import By


class MyLogin(Base):
    def theclose(self):
        # 关闭弹窗
        self.click((By.XPATH,'//div[@class="panel-cross"]/span'))
    def theclick(self):
        # 点击登录的框
        self.click((By.ID,'cloudLogin'))
    def username(self,content='root1234'):
        # 输入账号
        self.send_keys((By.NAME,'username'),content)
    def password(self,content='root1234'):
        # 输入密码
        self.send_keys((By.NAME,'password'),content)
    def login(self):
        # 点击登录
        self.click((By.XPATH,'//div/input[@class="btn-a"]'))

